home *** CD-ROM | disk | FTP | other *** search
/ The Utilities Experience / The Utilities Experience - Volume 1.iso / software / comms / mosiac / mosaic_1.2_as225r2 / contrib / mshunt / mosaic_shunt.doc < prev    next >
Text File  |  1978-06-29  |  5KB  |  125 lines

  1. Mosaic_Shunt 1.0
  2. An AREXX script for Amiga Mosaic
  3.  
  4. (c) 1994 Aaron Weiss
  5.  
  6. DISCLAIMER(S): This product is ImproveWare (tm), which means that it is Freely
  7. Distributable and modifiable; just give me credit somewhere. Please, 
  8. I beg of you.  Considering that this is my first AREXX program, and not
  9. all that an important one at that, it would benefit all if anyone with
  10. more AREXX panache than me could gussy it up more. Nonetheless, I am the
  11. original author and want to be immorta--er, remembered that way. Thanks.
  12.  
  13. Introduction
  14.  
  15. One of the "problems" (features, or whatever your fancy) of Amiga Mosaic is
  16. that whenever it retrieves a file destined for external viewing, it transfers
  17. the file into some temp file, send it along its way via the commandline
  18. provided in the .mailcap file, and then deletes it. One of the unfortunate
  19. side effects of this behavior is that should the file fail to be deal with
  20. correctly, such as if you didn't have enough memory to display it, 
  21. Amiga Mosaic would delete it before you could even gasp for help. Furthermore,
  22. sometimes, even if the file did show/sound correctly, you might want to save
  23. it anyway for future viewing and/or listening pleasure. Hence this shunt,
  24. which reroutes, via the .mailcap file, said file and deals with it in
  25. a friendlier manner.
  26.  
  27. Overview of the Shunt
  28.  
  29. In short, this program works on the following logic:
  30.  
  31. 1) Figure out what type of file this is (i.e. GIF, JPEG, 8SVX, etc.)
  32. 2) Send it to be shown/played via appropriate program
  33. 3) Allow the user the option of saving it for future use
  34.                                                         
  35.  
  36. INSTALLATION
  37.  
  38. Just put this wherever you want, though REXX: seems a nice and
  39. logical place. Then call it in the .mailcap entries rather than
  40. whatever you are calling now. For example, use the entry:
  41.  
  42. image/*; rx REXX:mosaic_shunt.rexx %s
  43.  
  44. in the .mailcap. If you're reading this file you probably know how
  45. to use the .mailcap by now, so I won't bore you any longer with this.
  46. Note that this archive includes two versions of the program, one
  47. with all explanatory comments in place for beauty's sake, and the
  48. other with them all stripped out for speed's sake. Use whichever
  49. tickles you most.
  50.  
  51. Use and Operation
  52.  
  53. Using the shunt is easy, once you know how! In it's current
  54. state it has no external preferences file, as such, so all
  55. user preference changes are made in the code at the top
  56. of the program. Considering that this is all well marked
  57. out and commented within the code, I really don't think this
  58. is much of a problem. An external prefs file might be forseeable,
  59. but only if I really find it necessary.
  60.  
  61. Here's a quick and dirty run down of the settings, and I think
  62. this should more than cover it:
  63.  
  64. savemode=x
  65.  
  66. x may equal the number 1, 2, or 3, each meaning the following:
  67. 1 - Never save the file, just try to show it and return to Amiga Mosaic.
  68. 2 - Option to save file.
  69.     After attempting to show or play the file, an ASL file requestor
  70.     will appear, from where you can choose a place and name for the file
  71.     to be saved. Alternatively, you can hit CANCEL in the requestor
  72.     and abort the save.
  73. 3 - Always save file. This won't annoy you with a file requestor
  74.     after every externally spawned file, but it will use the
  75.     cryptic filename that Amiga Mosaic used to save the file
  76.     originally, only this time it will be placed in your
  77.     preference defined save drawer (to be discussed next).
  78.     
  79. savedrawer=STRING
  80.  
  81. Just enter STRING as the name of the drawer you want
  82. to save automatic (#3 above) files to, or that the
  83. file requestor will default to (#2 above). Note that
  84. the STRING should be between single quotes (') and, 
  85. of course, if your drawer name has spaces use double-
  86. quotes around that (") within the single quotes. Some examples:
  87.  
  88. savedrawer='temp:pix/mosaicpix'
  89. savedrawer='temp:pix'
  90. savedrawer='"temp:Mosaic Pictures"'
  91.  
  92. The rest of the settings are for the viewers themselves. Note
  93. that this is not a flexible system, and as such only currently
  94. supports viewers for JPEG, GIF, IFF, ANIM, 8SVX, and AU format files.
  95. Adding others is rather trivial, and I probably will in the very
  96. near future, once I learn what to parse for in their headers.
  97.  
  98. For these, just enter the commandline, between single
  99. quotes, that you would normally use to execute the program
  100. from a shell. Use path and parameters as necessary. Insert a
  101. %s wherever the filename would normally go, and note that you
  102. CAN use multiple %s in the same line if you want the filename
  103. to appear more than once on a line. Some examples:
  104.  
  105. iffviewer='graphics:vt/vt screenmode="super72:super-high res laced" %s'
  106.  
  107. Note the use of double-quotes above where they would normally be
  108. necessary in this command were it in a shell.
  109.  
  110. gifviewer='graphics:vt/vt %s SAVE %s.iff'
  111.  
  112. This execute ViewTek using the parameter for saving the displayed
  113. picture as an IFF. 
  114.  
  115. ...well, that's all! I can't think of much else to say, except that
  116. I will continually try to improve this - and my AREXX skills at the
  117. same time - as I play with Amiga Mosaic, and as it improves
  118. (great job, guys!). 
  119.  
  120. Questions, Comments, Complaints, Refunds, Hot Email to
  121.  
  122. Aaron Weiss
  123. mw12@crux2.cit.cornell.edu (at _least_ until 5/94. after that who knows?)
  124.  
  125.